<%@page import="java.util.ArrayList"%>
<%@page import="cn.jhc.dao.ConnectionFactory"%>
<%@page import="cn.jhc.dao.ShowmvDAO"%>
<%@page import="cn.jhc.bean.ShowmvBean"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="css/flash.css"></link>
<title>每月之星</title>
</head>
<body>
	<%
		int CurrentPage = 1;
		int intPageCount;
		if (request.getParameter("page") != null)
			CurrentPage = Integer.parseInt(request.getParameter("page"));
		if (CurrentPage < 1)
			CurrentPage = 1;
		int newsCount=10;
		int MsgCount;
	%>
	<div id="wrapper">
		<jsp:include page="./header.jsp"></jsp:include>
		<div id="address">
			<a>当前位置： 每月之星</a>
		</div>
		<div id="ImageTitle">
			<% 
				ArrayList<ShowmvBean> s = new ArrayList<ShowmvBean>();
				ShowmvDAO dao = new ShowmvDAO();
				dao.setCon(ConnectionFactory.getConnection());
				s = dao.getAllTitle(CurrentPage,newsCount);
				request.setAttribute("title", s);
			%>
			<%
				ShowmvBean a = new ShowmvBean();
				dao.setCon(ConnectionFactory.getConnection());
				a = dao.getOneTitle();
				request.setAttribute("onetitle",a);
			%>
			<div id="lastStar"><a>上月之星</a></div>
			<div id="OneimageTitle">
				<div class="image"><a href="showonemv.jsp?id=${requestScope.onetitle.id}"><img src="UserFiles/Flash/${requestScope.onetitle.imagename}" width="200" height="150"></a></div>
				<div class="title">
					<div id="title2"><a href="showonemv.jsp?id=${requestScope.onetitle.id}">${requestScope.onetitle.title}</a></div>
					<div class="num"><a>获得票数：${requestScope.onetitle.agreed}&nbsp;&nbsp;&nbsp;&nbsp;反对票：${requestScope.onetitle.against}</a></div>
					<div class="date"><a>发布时间：${requestScope.onetitle.date}</a></div>
				</div>
			</div>
			<div id="theStar"><a>本月之星评选</a></div>
			<div id="ALL">
			<c:forEach items="${requestScope.title}" var="tit">
				<div id="alltitle">
					<div class="image"><a href="showonemv.jsp?id=${tit.id}"><img src="UserFiles/Flash/${tit.imagename}" width="200" height="150"></a></div>
					<div class="title">
						<div id="title2"><a href="showonemv.jsp?id=${tit.id}">${tit.title}</a></div>
						<div class="num"><a>获得票数：${tit.agreed}&nbsp;&nbsp;&nbsp;&nbsp;反对票：${tit.against}</a></div>
						<div class="date"><a>发布时间：${tit.date}</a></div>
					</div>
				</div>
			</c:forEach>
			</div>
		</div>
	<div id="down_bg"></div>
	<div id="line2">
	</div>
	<div id="copyright">
			<a>&copy;版权所有:蓝调吉他社　</a><a>|　</a>
			<div id="admin">
				<a href="houtai_index.jsp">管理员登录</a>
			</div>
	</div>
	</div>
</body>
</html>